#define _CRT_SECURE_NO_WARNINGS	

#include<stdio.h>

int main()
{
    for (int i = 1; i <= 5; i++)
    {
        for (int space = 0; space < 5 - i; space++)
            printf(" ");
        for (int a = 1; a < i; a++)
            printf("%d", a);
        printf("%d", i);
        for (int b = i - 1; b > 0; b--)
            printf("%d", b);
        printf("\n");
    }
    return 0;
}